<?php 
/*
 module:		用户管理控制器
 create_time:	2023-04-13 15:08:07
 author:		
 contact:		
*/

namespace app\admin\validate;
use think\validate;

class Adminuser extends validate {


	protected $rule = [
		'mobile'=>['require','regex'=>'/^1[3456789]\d{9}$/'],
		'email'=>['regex'=>'/^([a-zA-Z0-9_-])+@([a-zA-Z0-9_-])+(.[a-zA-Z0-9_-])+/'],
	];

	protected $message = [
		'mobile.require'=>'手机号码不能为空',
		'mobile.regex'=>'手机号码格式错误',
		'email.regex'=>'电子邮箱格式错误',
	];

	protected $scene  = [
		'add'=>['mobile','email'],
		'update'=>['mobile','email'],
	];



}

